<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Class image3d</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../index.html" title="Chapter 1. Boost.Compute">
<link rel="up" href="../../boost_compute/reference.html#header.boost.compute.image.image3d_hpp" title="Header &lt;boost/compute/image/image3d.hpp&gt;">
<link rel="prev" href="image2d.html" title="Class image2d">
<link rel="next" href="image_format.html" title="Class image_format">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="image2d.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../../boost_compute/reference.html#header.boost.compute.image.image3d_hpp"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="image_format.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="refentry">
<a name="boost.compute.image3d"></a><div class="titlepage"></div>
<div class="refnamediv">
<h2><span class="refentrytitle">Class image3d</span></h2>
<p>boost::compute::image3d — An OpenCL 3D image object. </p>
</div>
<h2 xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="refsynopsisdiv-title">Synopsis</h2>
<div xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="refsynopsisdiv"><pre class="synopsis"><span class="comment">// In header: &lt;<a class="link" href="../../boost_compute/reference.html#header.boost.compute.image.image3d_hpp" title="Header &lt;boost/compute/image/image3d.hpp&gt;">boost/compute/image/image3d.hpp</a>&gt;

</span>
<span class="keyword">class</span> <a class="link" href="image3d.html" title="Class image3d">image3d</a> <span class="special">:</span> <span class="keyword">public</span> <span class="identifier">boost</span><span class="special">::</span><span class="identifier">compute</span><span class="special">::</span><span class="identifier">image_object</span> <span class="special">{</span>
<span class="keyword">public</span><span class="special">:</span>
  <span class="comment">// <a class="link" href="image3d.html#boost.compute.image3dconstruct-copy-destruct">construct/copy/destruct</a></span>
  <a class="link" href="image3d.html#idm45822165856640-bb"><span class="identifier">image3d</span></a><span class="special">(</span><span class="special">)</span><span class="special">;</span>
  <a class="link" href="image3d.html#idm45822165855344-bb"><span class="identifier">image3d</span></a><span class="special">(</span><span class="keyword">const</span> <span class="identifier">context</span> <span class="special">&amp;</span><span class="special">,</span> <span class="identifier">size_t</span><span class="special">,</span> <span class="identifier">size_t</span><span class="special">,</span> <span class="identifier">size_t</span><span class="special">,</span> <span class="keyword">const</span> <a class="link" href="image_format.html" title="Class image_format">image_format</a> <span class="special">&amp;</span><span class="special">,</span> 
          <span class="identifier">cl_mem_flags</span> <span class="special">=</span> <span class="identifier">read_write</span><span class="special">,</span> <span class="keyword">void</span> <span class="special">*</span> <span class="special">=</span> <span class="number">0</span><span class="special">,</span> <span class="identifier">size_t</span> <span class="special">=</span> <span class="number">0</span><span class="special">,</span> <span class="identifier">size_t</span> <span class="special">=</span> <span class="number">0</span><span class="special">)</span><span class="special">;</span>
  <a class="link" href="image3d.html#idm45822165845040-bb"><span class="identifier">image3d</span></a><span class="special">(</span><span class="keyword">const</span> <a class="link" href="image3d.html" title="Class image3d">image3d</a> <span class="special">&amp;</span><span class="special">)</span><span class="special">;</span>
  <a class="link" href="image3d.html#idm45822165838704-bb"><span class="identifier">image3d</span></a><span class="special">(</span><a class="link" href="image3d.html" title="Class image3d">image3d</a> <span class="special">&amp;&amp;</span><span class="special">)</span> <span class="keyword">noexcept</span><span class="special">;</span>
  <a class="link" href="image3d.html" title="Class image3d">image3d</a> <span class="special">&amp;</span> <a class="link" href="image3d.html#idm45822165842160-bb"><span class="keyword">operator</span><span class="special">=</span></a><span class="special">(</span><span class="keyword">const</span> <a class="link" href="image3d.html" title="Class image3d">image3d</a> <span class="special">&amp;</span><span class="special">)</span><span class="special">;</span>
  <a class="link" href="image3d.html" title="Class image3d">image3d</a> <span class="special">&amp;</span> <a class="link" href="image3d.html#idm45822165836400-bb"><span class="keyword">operator</span><span class="special">=</span></a><span class="special">(</span><a class="link" href="image3d.html" title="Class image3d">image3d</a> <span class="special">&amp;&amp;</span><span class="special">)</span> <span class="keyword">noexcept</span><span class="special">;</span>
  <a class="link" href="image3d.html#idm45822165833088-bb"><span class="special">~</span><span class="identifier">image3d</span></a><span class="special">(</span><span class="special">)</span><span class="special">;</span>

  <span class="comment">// <a class="link" href="image3d.html#idm45822165872544-bb">public member functions</a></span>
  <a class="link" href="extents.html" title="Class template extents">extents</a><span class="special">&lt;</span> <span class="number">3</span> <span class="special">&gt;</span> <a class="link" href="image3d.html#idm45822165871984-bb"><span class="identifier">size</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <a class="link" href="extents.html" title="Class template extents">extents</a><span class="special">&lt;</span> <span class="number">3</span> <span class="special">&gt;</span> <a class="link" href="image3d.html#idm45822165870256-bb"><span class="identifier">origin</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="identifier">T</span> <a class="link" href="image3d.html#idm45822165867200-bb"><span class="identifier">get_info</span></a><span class="special">(</span><span class="identifier">cl_image_info</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">int</span> Enum<span class="special">&gt;</span> <span class="emphasis"><em><span class="identifier">unspecified</span></em></span> <a class="link" href="image3d.html#idm45822165863024-bb"><span class="identifier">get_info</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <a class="link" href="image3d.html" title="Class image3d">image3d</a> <a class="link" href="image3d.html#idm45822165860096-bb"><span class="identifier">clone</span></a><span class="special">(</span><span class="identifier">command_queue</span> <span class="special">&amp;</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>

  <span class="comment">// <a class="link" href="image3d.html#idm45822165831792-bb">public static functions</a></span>
  <span class="keyword">static</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special">&lt;</span> <a class="link" href="image_format.html" title="Class image_format">image_format</a> <span class="special">&gt;</span> 
  <a class="link" href="image3d.html#idm45822165831232-bb"><span class="identifier">get_supported_formats</span></a><span class="special">(</span><span class="keyword">const</span> <span class="identifier">context</span> <span class="special">&amp;</span><span class="special">,</span> <span class="identifier">cl_mem_flags</span> <span class="special">=</span> <span class="identifier">read_write</span><span class="special">)</span><span class="special">;</span>
  <span class="keyword">static</span> <span class="keyword">bool</span> <a class="link" href="image3d.html#idm45822165826432-bb"><span class="identifier">is_supported_format</span></a><span class="special">(</span><span class="keyword">const</span> <a class="link" href="image_format.html" title="Class image_format">image_format</a> <span class="special">&amp;</span><span class="special">,</span> <span class="keyword">const</span> <span class="identifier">context</span> <span class="special">&amp;</span><span class="special">,</span> 
                                  <span class="identifier">cl_mem_flags</span> <span class="special">=</span> <span class="identifier">read_write</span><span class="special">)</span><span class="special">;</span>
<span class="special">}</span><span class="special">;</span></pre></div>
<div class="refsect1">
<a name="idm46604975382704"></a><h2>Description</h2>
<p><span class="bold"><strong>See Also:</strong></span></p>
<p><a class="link" href="image_format.html" title="Class image_format">image_format</a>, <a class="link" href="image2d.html" title="Class image2d">image2d</a> </p>
<p>
</p>
<p>
</p>
<div class="refsect2">
<a name="idm46604975379504"></a><h3>
<a name="boost.compute.image3dconstruct-copy-destruct"></a><code class="computeroutput">image3d</code> 
        public
       construct/copy/destruct</h3>
<div class="orderedlist"><ol class="orderedlist" type="1">
<li class="listitem">
<pre class="literallayout"><a name="idm45822165856640-bb"></a><span class="identifier">image3d</span><span class="special">(</span><span class="special">)</span><span class="special">;</span></pre>Creates a null <code class="computeroutput"><a class="link" href="image3d.html" title="Class image3d">image3d</a></code> object. </li>
<li class="listitem">
<pre class="literallayout"><a name="idm45822165855344-bb"></a><span class="identifier">image3d</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">context</span> <span class="special">&amp;</span> context<span class="special">,</span> <span class="identifier">size_t</span> image_width<span class="special">,</span> <span class="identifier">size_t</span> image_height<span class="special">,</span> 
        <span class="identifier">size_t</span> image_depth<span class="special">,</span> <span class="keyword">const</span> <a class="link" href="image_format.html" title="Class image_format">image_format</a> <span class="special">&amp;</span> format<span class="special">,</span> 
        <span class="identifier">cl_mem_flags</span> flags <span class="special">=</span> <span class="identifier">read_write</span><span class="special">,</span> <span class="keyword">void</span> <span class="special">*</span> host_ptr <span class="special">=</span> <span class="number">0</span><span class="special">,</span> 
        <span class="identifier">size_t</span> image_row_pitch <span class="special">=</span> <span class="number">0</span><span class="special">,</span> <span class="identifier">size_t</span> image_slice_pitch <span class="special">=</span> <span class="number">0</span><span class="special">)</span><span class="special">;</span></pre>
<p>Creates a new <code class="computeroutput"><a class="link" href="image3d.html" title="Class image3d">image3d</a></code> object.</p>
<p>See the documentation for <a href="http://www.khronos.org/registry/cl/sdk/1.2/docs/man/xhtml/clCreateImage.html" target="_top">clCreateImage()</a> for more information. </p>
</li>
<li class="listitem">
<pre class="literallayout"><a name="idm45822165845040-bb"></a><span class="identifier">image3d</span><span class="special">(</span><span class="keyword">const</span> <a class="link" href="image3d.html" title="Class image3d">image3d</a> <span class="special">&amp;</span> other<span class="special">)</span><span class="special">;</span></pre>Creates a new <code class="computeroutput"><a class="link" href="image3d.html" title="Class image3d">image3d</a></code> as a copy of <code class="computeroutput">other</code>. </li>
<li class="listitem">
<pre class="literallayout"><a name="idm45822165838704-bb"></a><span class="identifier">image3d</span><span class="special">(</span><a class="link" href="image3d.html" title="Class image3d">image3d</a> <span class="special">&amp;&amp;</span> other<span class="special">)</span> <span class="keyword">noexcept</span><span class="special">;</span></pre>Move-constructs a new image object from <code class="computeroutput">other</code>. </li>
<li class="listitem">
<pre class="literallayout"><a class="link" href="image3d.html" title="Class image3d">image3d</a> <span class="special">&amp;</span> <a name="idm45822165842160-bb"></a><span class="keyword">operator</span><span class="special">=</span><span class="special">(</span><span class="keyword">const</span> <a class="link" href="image3d.html" title="Class image3d">image3d</a> <span class="special">&amp;</span> other<span class="special">)</span><span class="special">;</span></pre>Copies the <code class="computeroutput"><a class="link" href="image3d.html" title="Class image3d">image3d</a></code> from <code class="computeroutput">other</code>. </li>
<li class="listitem">
<pre class="literallayout"><a class="link" href="image3d.html" title="Class image3d">image3d</a> <span class="special">&amp;</span> <a name="idm45822165836400-bb"></a><span class="keyword">operator</span><span class="special">=</span><span class="special">(</span><a class="link" href="image3d.html" title="Class image3d">image3d</a> <span class="special">&amp;&amp;</span> other<span class="special">)</span> <span class="keyword">noexcept</span><span class="special">;</span></pre>Move-assigns the image from <code class="computeroutput">other</code> to <code class="computeroutput">*this</code>. </li>
<li class="listitem">
<pre class="literallayout"><a name="idm45822165833088-bb"></a><span class="special">~</span><span class="identifier">image3d</span><span class="special">(</span><span class="special">)</span><span class="special">;</span></pre>Destroys the <code class="computeroutput"><a class="link" href="image3d.html" title="Class image3d">image3d</a></code> object. </li>
</ol></div>
</div>
<div class="refsect2">
<a name="idm46604975306320"></a><h3>
<a name="idm45822165872544-bb"></a><code class="computeroutput">image3d</code> public member functions</h3>
<div class="orderedlist"><ol class="orderedlist" type="1">
<li class="listitem">
<pre class="literallayout"><a class="link" href="extents.html" title="Class template extents">extents</a><span class="special">&lt;</span> <span class="number">3</span> <span class="special">&gt;</span> <a name="idm45822165871984-bb"></a><span class="identifier">size</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>Returns the size (width, height, depth) of the image. </li>
<li class="listitem">
<pre class="literallayout"><a class="link" href="extents.html" title="Class template extents">extents</a><span class="special">&lt;</span> <span class="number">3</span> <span class="special">&gt;</span> <a name="idm45822165870256-bb"></a><span class="identifier">origin</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>Returns the origin of the image (<code class="computeroutput">0</code>, <code class="computeroutput">0</code>, <code class="computeroutput">0</code>). </li>
<li class="listitem">
<pre class="literallayout"><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="identifier">T</span> <a name="idm45822165867200-bb"></a><span class="identifier">get_info</span><span class="special">(</span><span class="identifier">cl_image_info</span> info<span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>
<p>Returns information about the image.</p>
<p>See the documentation for <a href="http://www.khronos.org/registry/cl/sdk/1.2/docs/man/xhtml/clGetImageInfo.html" target="_top">clGetImageInfo()</a> for more information. </p>
</li>
<li class="listitem">
<pre class="literallayout"><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">int</span> Enum<span class="special">&gt;</span> <span class="emphasis"><em><span class="identifier">unspecified</span></em></span> <a name="idm45822165863024-bb"></a><span class="identifier">get_info</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>
<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
</li>
<li class="listitem">
<pre class="literallayout"><a class="link" href="image3d.html" title="Class image3d">image3d</a> <a name="idm45822165860096-bb"></a><span class="identifier">clone</span><span class="special">(</span><span class="identifier">command_queue</span> <span class="special">&amp;</span> queue<span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>
<p>Creates a new image with a copy of the data in <code class="computeroutput">*this</code>. Uses <code class="computeroutput">queue</code> to perform the copy operation. </p>
</li>
</ol></div>
</div>
<div class="refsect2">
<a name="idm46604975261776"></a><h3>
<a name="idm45822165831792-bb"></a><code class="computeroutput">image3d</code> public static functions</h3>
<div class="orderedlist"><ol class="orderedlist" type="1">
<li class="listitem">
<pre class="literallayout"><span class="keyword">static</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special">&lt;</span> <a class="link" href="image_format.html" title="Class image_format">image_format</a> <span class="special">&gt;</span> 
<a name="idm45822165831232-bb"></a><span class="identifier">get_supported_formats</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">context</span> <span class="special">&amp;</span> context<span class="special">,</span> 
                      <span class="identifier">cl_mem_flags</span> flags <span class="special">=</span> <span class="identifier">read_write</span><span class="special">)</span><span class="special">;</span></pre>
<p>Returns the supported 3D image formats for the context.</p>
<p>See the documentation for <a href="http://www.khronos.org/registry/cl/sdk/1.2/docs/man/xhtml/clGetSupportedImageFormats.html" target="_top">clGetSupportedImageFormats()</a> for more information. </p>
</li>
<li class="listitem">
<pre class="literallayout"><span class="keyword">static</span> <span class="keyword">bool</span> <a name="idm45822165826432-bb"></a><span class="identifier">is_supported_format</span><span class="special">(</span><span class="keyword">const</span> <a class="link" href="image_format.html" title="Class image_format">image_format</a> <span class="special">&amp;</span> format<span class="special">,</span> 
                                <span class="keyword">const</span> <span class="identifier">context</span> <span class="special">&amp;</span> context<span class="special">,</span> 
                                <span class="identifier">cl_mem_flags</span> flags <span class="special">=</span> <span class="identifier">read_write</span><span class="special">)</span><span class="special">;</span></pre>
<p>Returns <code class="computeroutput">true</code> if <code class="computeroutput">format</code> is a supported 3D image format for <code class="computeroutput">context</code>. </p>
</li>
</ol></div>
</div>
</div>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2013, 2014 Kyle Lutz<p>
        Distributed under the Boost Software License, Version 1.0. (See accompanying
        file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
      </p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="image2d.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../../boost_compute/reference.html#header.boost.compute.image.image3d_hpp"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="image_format.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>
